import QtQuick 2.15
import QtQuick.Controls 2.15

import '../component'
ApplicationWindow {
	width: 800; height: 700
	visible: true
	
	DarkSquare{
		id:root
		width:252
		height:252
		property variant  colorArray: ['#00BDE3','#67C111','#EA7025']
		
		Grid{
			anchors.fill:parent
			anchors.margins:8
			spacing:4
			Repeater{
				model: 16
				Rectangle{
					width:56
					height:56
					property int colorIndex:Math.floor(Math.random()*3)
					color:root.colorArray[colorIndex]
					border.color:Qt.lighter(color)
					Text{
						anchors.centerIn:parent
						color:'#F0F0F0'
						text: 'Cell' + index
					}
				}
			}
		}
	}
	
}